@model IEnumerable<aspnetcore.Models.SysConfig>
@{
    ViewData["Title"] = "系统配置";
}

<h1>系统配置表</h1>

<table class="table table-bordered">
    <thead>
        <tr>
            <td>ID</td>
            <td>Name</td>
            <td>Val</td>
            <td>Desc</td>
            <td>CreateTime</td>
            <td>Option</td>
        </tr>
    </thead>
    <tbody>
        
        @foreach(var config in Model) {
            <tr>
                <td>@config.Id</td>
                <td>@config.Name</td>
                <td>@config.Val</td>
                <td>@config.Description</td>
                <td>@config.Create_Time.ToString("yyyy-MM-dd HH:mm:ss")</td>
                <td>
                    <button type="button" class="btn btn-xs btn-default">编辑</button>
                </td>
            </tr>
        }
    </tbody>
</table>

<h1>添加 / 修改 系统配置配置</h1>

<div class="row">
    <form class="col-md-4">
    <div class="form-group">
        <label for="txtName">名称</label>
        <input type="text" class="form-control" id="txtName" placeholder="名称">
    </div>
    <div class="form-group">
        <label for="txtVal">值</label>
        <input type="text" class="form-control" id="txtVal" placeholder="值">
    </div>
    <div class="form-group">
        <label for="txtDesc">描述</label>
        <input type="text" class="form-control" id="txtDesc" placeholder="描述">
    </div>
    <button type="submit" class="btn btn-success">保存</button>
    </form>
</div>
